<?php
	include_once 'isLogin.php';
	$userc=new user();
	$table= 'user_message';  	  		 	  //咨询表
	$table_list= 'user_message_list';  	  		 	  //咨询表

	$id=$_GET['id'];

	//修改
	if($id!='' && $id!=null){
		$row=$userc->message_info($id);
		@$row['create_time']=date('Y-m-d H:i:s',$row['create_time']);
	
		//读取标签
		$select_user=$commonc->getList($table_list." WHERE msg_id=".$row['id']." ORDER BY id");
		$select_user=$select_user['result'];


		if (is_array($select_user)) {
		 	foreach ($select_user as $k1 => $v1) {
		 		$user_id.=$v1['user_id'].",";	
		 	}
		 	$user_id=substr($user_id,0,-1);
			$user_list=$commonc->getList("user WHERE id in(".$user_id.")");

			$smarty->assign('user_list',$user_list['result']);
		}

		$smarty->assign('row',$row);
	}


	
	$smarty->display("user_message_info.html");
?>